/*  1:   */ package org.jetbrains.jps.model.java.impl;
/*  2:   */ 
/*  3:   */

import com.intellij.util.SmartList;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.jps.model.module.JpsDependencyElement;
import org.jetbrains.jps.model.module.JpsModule;
import org.jetbrains.jps.service.JpsServiceManager;

import java.util.Collection;
import java.util.List;

/*  4:   */
/*  5:   */
/*  6:   */
/*  7:   */
/*  8:   */
/*  9:   */
/* 10:   */
/* 11:   */ 
/* 12:   */ public abstract class JpsJavaDependenciesEnumerationHandler
/* 13:   */ {
/* 14:   */   public static List<JpsJavaDependenciesEnumerationHandler> createHandlers(Collection<JpsModule> paramCollection)
/* 15:   */   {
/* 16:33 */     SmartList localSmartList = null;
/* 17:34 */     for (Factory localFactory : JpsServiceManager.getInstance().getExtensions(Factory.class))
/* 18:   */     {
/* 19:35 */       JpsJavaDependenciesEnumerationHandler localJpsJavaDependenciesEnumerationHandler = localFactory.createHandler(paramCollection);
/* 20:36 */       if (localJpsJavaDependenciesEnumerationHandler != null)
/* 21:   */       {
/* 22:37 */         if (localSmartList == null) {
/* 23:38 */           localSmartList = new SmartList();
/* 24:   */         }
/* 25:40 */         localSmartList.add(localJpsJavaDependenciesEnumerationHandler);
/* 26:   */       }
/* 27:   */     }
/* 28:43 */     return localSmartList;
/* 29:   */   }
/* 30:   */   
/* 31:   */   public static boolean shouldProcessDependenciesRecursively(List<JpsJavaDependenciesEnumerationHandler> paramList)
/* 32:   */   {
/* 33:47 */     if (paramList != null) {
/* 34:48 */       for (JpsJavaDependenciesEnumerationHandler localJpsJavaDependenciesEnumerationHandler : paramList) {
/* 35:49 */         if (!localJpsJavaDependenciesEnumerationHandler.shouldProcessDependenciesRecursively()) {
/* 36:50 */           return false;
/* 37:   */         }
/* 38:   */       }
/* 39:   */     }
/* 40:54 */     return true;
/* 41:   */   }
/* 42:   */   
/* 43:   */   public boolean shouldAddRuntimeDependenciesToTestCompilationClasspath()
/* 44:   */   {
/* 45:63 */     return false;
/* 46:   */   }
/* 47:   */   
/* 48:   */   public boolean isProductionOnTestsDependency(JpsDependencyElement paramJpsDependencyElement)
/* 49:   */   {
/* 50:67 */     return false;
/* 51:   */   }
/* 52:   */   
/* 53:   */   public boolean shouldIncludeTestsFromDependentModulesToTestClasspath()
/* 54:   */   {
/* 55:71 */     return true;
/* 56:   */   }
/* 57:   */   
/* 58:   */   public boolean shouldProcessDependenciesRecursively()
/* 59:   */   {
/* 60:75 */     return true;
/* 61:   */   }
/* 62:   */   
/* 63:   */   public static abstract class Factory
/* 64:   */   {
/* 65:   */     @Nullable
/* 66:   */     public abstract JpsJavaDependenciesEnumerationHandler createHandler(@NotNull Collection<JpsModule> paramCollection);
/* 67:   */   }
/* 68:   */ }



/* Location:           E:\idea\

 * Qualified Name:     org.jetbrains.jps.model.java.impl.JpsJavaDependenciesEnumerationHandler

 * JD-Core Version:    0.7.0.1

 */